V = Variables
C = Calculation functions
The VC10Calendar function calculates the day of the week (iin numerical form see the Note) starting from the date expressed as day, month and year starting from 1/1/2000.
The function sets a negative value if you passed a wrong topic. The value determines the type of error.
VC10Calendar (day, month, year, numday)
Parameters:
| IN/OUT | VARIABLE TYPE | EXAMPLE NAME | DIM | |
|---|---|---|---|---|
| IN | SYSTEM | day | L | Number of the day (1÷31) |
| IN | SYSTEM | month | L | Number of the month (1÷12) |
| IN | SYSTEM | year | L | Year - 4 digits - (from 2000 onwards) |
| OUT | SYSTEM | numday | L | Day of the week expressed in number: 0 = Sunday 1 = Monday 2 = Tuesday 3 = Wednesday 4 = Thursday 5 = Friday 6 = Saturday |
Se ci fosse qualche errore di introduzione dei dati verrebbe segnalato sulla variabile numgiorno con dei valori negativi. In particolare:
-1 = errore nell'immissione del giorno
-2 = errore nell'immissione del mese
-3 = errore nell'immissione dell'anno
-4 = errore nell'immissione del giorno mese febbraio
Nell'esempio, se il giorno della settimana del 19 giugno 2002 è mercoledì, si attiva l'uscita 'ofUscita'.
giorno = 19 mese = 6 anno = 2002 VC10Calendar (giorno, mese, anno, numgiorno) IF (numgiorno EQ 3) SETOUT ofUscita ENDIF